import { put, get, uploadFile } from '@/security/request'
import { Application_Form } from '@/utils/keyWord'

export function getPageApi(data: any): Promise<IPageResult<any>> {
    return get("/admin/avatar/getPage",  data);
}

export function updateApi(data: any): Promise<IRespResult<any>> {
    return put("/admin/avatar/update",  data, Application_Form);
}

export function updateCustomApi(filePath: any, data: any): Promise<IRespResult<any>> {
    return uploadFile("/admin/avatar/custom/update",  filePath, data);
}

export function getAvatarApi(data: any): Promise<IPageResult<any>> {
    return get("/admin/avatar/getAvatar",  data, Application_Form);
}
